﻿@model BookInventory.Dtos.AddBookDto
@{
    ViewData["Title"] = "Add Book";

    var action = Url.Action("Add", "BookInventory", new { Area = BookInventory.ModuleDefiniation.MODULE_NAME });
}

<h1>Add</h1>

<form action="@action" method="post" enctype="multipart/form-data">
    <div class="form-group">

        @Html.LabelFor(p => p.BookName)
        @Html.TextBoxFor(p => p.BookName, new { @class = "form-control" })

    </div>
    <div class="form-group">

        @Html.LabelFor(p => p.ISBN)
        @Html.TextBoxFor(p => p.ISBN, new { @class = "form-control" })

    </div>
    <div class="form-group">

        @Html.LabelFor(p => p.DateIssued)
        @Html.TextBoxFor(p => p.DateIssued, new { @class = "form-control" })

    </div>
    <div class="form-group">

        @Html.LabelFor(p => p.Description)
        @Html.TextBoxFor(p => p.BookName, new { @class = "form-control" })

    </div>
    <button type="submit" class="btn btn-primary">Submit</button>
</form>

@section Scripts{
    <script type="text/javascript">
        $(document).ready(function () {
            $('#@Html.IdFor(p=>p.DateIssued)').datepicker();
        });
    </script>
} 